package demo4;

import java.util.Stack;

public class Test {
    public static void main(String[] args) {
        MyStack stack = new MyStack();
        stack.push(1);
        stack.push(2);

        int val = stack.pop();
        System.out.println(val);

        val = stack.top();
        System.out.println(val);

        Stack<Integer> s1 = new Stack<>();
        s1.empty();
        s1.add(2);
        s1.pop();
        s1.peek();
    }
}
